package com.quanyan.pay.service;

import com.quanyan.alipay.config.AlipayConfig;
import com.quanyan.api.APIRequest;
import com.quanyan.api.APIResponse;
import com.quanyan.common.Plugin.PageObj;
import com.quanyan.pay.entity.AlipayAccount;
import com.quanyan.pay.entity.WeichatAccount;
import com.quanyan.pay.vo.response.PayAccount;
import com.quanyan.pay.web.request.ReqAlipayAccount;
import com.quanyan.pay.web.request.ReqWeichatAccount;

import java.util.List;

/**
 * 维护支付宝/微信账号/
 * Created by songzj on 16/5/30.
 */
public interface AccountService {


    /**
     * 阿里账户维护
     *
     * @param reqAlipayAccount
     * @return
     */
    APIResponse<AlipayAccount> insertOrUpdateAlipayAccount(APIRequest<ReqAlipayAccount> reqAlipayAccount);

    /**
     * 查询唯一支付宝支付账号
     *
     * @param reqAlipayAccount
     * @return
     */
    APIResponse<AlipayAccount> selectAlipayAccountByProperty(APIRequest<ReqAlipayAccount> reqAlipayAccount);

    /**
     * 查询支付宝账号列表
     *
     * @param reqAlipayAccount
     * @return
     */
    APIResponse<PageObj<List<AlipayAccount>>> selectAlipayAccountListByProperty(APIRequest<ReqAlipayAccount> reqAlipayAccount);


    /**
     * 微信账户维护
     *
     * @param reqWeichatAccount
     * @return
     */
    APIResponse<WeichatAccount> insertOrUpdateWeichatAccount(APIRequest<ReqWeichatAccount> reqWeichatAccount);


    /**
     * @param reqWeichatAccount
     * @return
     */
    APIResponse<WeichatAccount> selectWeichatAccountByProperty(APIRequest<ReqWeichatAccount> reqWeichatAccount);

    /**
     * @param reqWeichatAccount
     * @return
     */
    APIResponse<PageObj<List<WeichatAccount>>> selectWeichatAccountListByProperty(APIRequest<ReqWeichatAccount> reqWeichatAccount);


    AlipayConfig selectAlipayConfigBySellerIdAndEmail(String sellerId, String sellerEmail);

    PayAccount selectAllAccount();

}
